﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<IEnumerable<SLIC.Models.EntityModel.ImageGallery>>" %>
<div style="display: block; overflow: auto;">
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.PointsOfImpact.ToString(), true))).Count() > 0)
       {%>
    <div id="innerContainer" style="margin-top: 0px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                Points Of Impact</h3>
        </div>
        <%                foreach
                   (SLIC.Models.EntityModel.ImageGallery item in Model)
                          { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.PointsOfImpact.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
                          }
        %>
    </div>
    <%} %>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.DriverStatement.ToString(), true))).Count() > 0)
       {%>
    <div id="innerContainer" style="margin-top: 10px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                Driver Statement
            </h3>
        </div>
        <% 
           foreach
               (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.DriverStatement.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" />
        <br/><%=item.Title%>
        </div>
        <%}
       }
       }
        %>
    </div>
    <% if (Model != null && Model.Where(x =>
        x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName), SLIC.Models.Enums.FieldName.AccidentImages.ToString(),
        true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                Accident Images</h3>
        </div>
        <%   foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
             { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.AccidentImages.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
             }      %>
    </div>
    <%}%>
    <% if (Model != null && Model.Where(x =>
        x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName), SLIC.Models.Enums.FieldName.DLStatement.ToString(),
        true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                D/L Statement</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.DLStatement.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%} %>
    <%
        if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.TechnicalOfficerComments.ToString(), true))).Count()
        > 0)
        { %>
    <div id="innerContainer" style="margin-top: 10px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                Technical Officer Comments</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           {
        %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.TechnicalOfficerComments.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%} %>
    <%
        if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.ClaimFormImage.ToString(), true))).Count() > 0)
        { %>
    <div id="innerContainer" style="margin-top: 10px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                Claim Form Images</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.ClaimFormImage.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%}
    %>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.ARI.ToString(), true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                ARI</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.ARI.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%} %>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.DR.ToString(), true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                DR</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.DR.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%} %>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.SeenVisit.ToString(), true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                Seen Visit</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.SeenVisit.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%} %>
    <%
        if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.SpecialReport1.ToString(), true))).Count() > 0)
        { %>
    <div id="innerContainer" style="margin-top: 10px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                Special Report 1</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.SpecialReport1.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%}
    %>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.SpecialReport2.ToString(), true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                Special Report 2</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.SpecialReport2.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%}
    %>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.SpecialReport3.ToString(), true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px; clear: both;">
        <div class="ImageHeaderBox">
            <h3>
                Special Report 3</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.SpecialReport3.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%}
    %>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.Supplementary1.ToString(), true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px;">
        <div class="ImageHeaderBox">
            <h3>
                Supplementary 1</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.Supplementary1.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%}
    %>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.Supplementary2.ToString(), true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px;">
        <div class="ImageHeaderBox">
            <h3>
                Supplementary 2</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.Supplementary2.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%}%>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.Supplementary3.ToString(), true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px;">
        <div class="ImageHeaderBox">
            <h3>
                Supplementary 3</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.Supplementary3.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%}%>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.Supplementary4.ToString(), true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px;">
        <div class="ImageHeaderBox">
            <h3>
                Supplementary 4</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.Supplementary4.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%}%>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.Acknowledgment.ToString(), true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px;">
        <div class="ImageHeaderBox">
            <h3>
                Acknowledgment</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.Acknowledgment.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%}%>
    <% if (Model != null && Model.Where(x => x.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.SalvageReport.ToString(), true))).Count() > 0)
       { %>
    <div id="innerContainer" style="margin-top: 10px;">
        <div class="ImageHeaderBox">
            <h3>
                SalvageReport</h3>
        </div>
        <% foreach (SLIC.Models.EntityModel.ImageGallery item in Model)
           { %>
        <% if (item.FieldId.Equals((byte)Enum.Parse(typeof(SLIC.Models.Enums.FieldName),
        SLIC.Models.Enums.FieldName.SalvageReport.ToString(), true)))
           { %>
        <div id="ImageFrame">
            <img src="../../HandlerClasses/imagehandler.ashx?path=<%=ConfigurationManager.AppSettings["ImageSavePath"].ToString()
        %><%=item.ImagePath%>" /><br/><%=item.Title%>
        </div>
        <%}
           } %>
    </div>
    <%} %></div>
<%-- <p>
        <%: Html.ActionLink("Create New", "Create") %>
    </p>--%>
